package com.wl.application.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.wl.application.entity.User;
import com.wl.application.entity.vo.AllotVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * @author wl
 * @version 1.0
 * @date 2022/6/21
 * @description:
 */
public interface UserMapper extends BaseMapper<User> {
    @Select("select u.* from t_user u\n" +
            "where u.id not in(select uid from t_user_role where rid=#{allot.roleId})")
    Page<User> noAllotPower(@Param("page") Page<User> page,@Param("allot") AllotVo allotVo);
}
